home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Pascal Super Library
/
Pascal Super Library (CW International)(1997).bin
/
LIBRARY
/
TOOLPAS2
/
ATCP.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1992-04-22
|
681b
|
41 lines
{$m 10000,10000,10000}
uses dos;
var
line: string;
fd: text;
cmd: string[128];
cp: string;
begin
if paramcount <> 2 then
begin
writeln('usage: atcp filelist dest');
writeln('example: atcp $door.nam j:\tmp');
halt;
end;
cp := fsearch('CP.EXE',getenv('PATH'));
assign(fd,paramstr(1));
reset(fd);
while not eof(fd) do
begin
readln(fd,line);
if line > ' ' then
begin
cmd := line+' '+paramstr(2);
if cp > '' then
exec(cp,cmd)
else
exec(getenv('COMSPEC'),'/c copy '+cmd);
end;
end;
close(fd);
end.